package leetcode.editor.cn;

import java.util.Arrays;

/**
 * 救生艇
 * @author qulq
 * @date 2024-09-17 16:29:41
 */
public class T881_BoatsToSavePeople{
	 public static void main(String[] args) {
	 	 // 测试代码
	 	 Solution solution = new T881_BoatsToSavePeople().new Solution();
	 }
	 
// 力扣代码
//leetcode submit region begin(Prohibit modification and deletion)
class Solution {
//    public int numRescueBoats(int[] people, int limit) {
//		if (people == null || people.length == 0) {
//			return 0;
//		}
//		Arrays.sort(people);
//		int ans = 0, left = 0, right = people.length - 1;
//		while (left <= right) {
//			if (people[left] + people[right] <= limit) {
//				left++;
//			}
//		}
//    }
}
//leetcode submit region end(Prohibit modification and deletion)

}